package com.topvision.controller;

import com.topvision.common.response.SuccessResponse;
import com.topvision.domain.SysTech;
import com.topvision.service.SysTechService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

/**
 * @author shengwm
 * @create 2018-04-23 16:28
 **/
public class SysTechController {

    @Autowired
    private SysTechService sysTechService;

    @GetMapping("/createGroup/{title}")
    public ResponseEntity createGroup(@PathVariable String title) {
        SysTech sysTech = new SysTech();
        // group.setName("topvision");
        sysTechService.save(sysTech);
        return ResponseEntity.ok(SuccessResponse.of(sysTech));
    }

}
